package cn.pupil.demo.design.domain.model.aggregates;

import cn.pupil.demo.design.domain.model.vo.TreeNode;
import cn.pupil.demo.design.domain.model.vo.TreeRoot;

import java.util.Map;

/**
 * @Description: 规则树聚合
 * @Author: pupil
 * @Date: 2024/07/25 下午 4:24
 */
public class TreeRich {

    private TreeRoot treeRoot; // 规则树根节点
    private Map<Long, TreeNode> nodeTreeMap; // 树节点ID -> 子节点

    public TreeRich() {
    }

    public TreeRich(TreeRoot treeRoot, Map<Long, TreeNode> nodeTreeMap) {
        this.treeRoot = treeRoot;
        this.nodeTreeMap = nodeTreeMap;
    }

    public TreeRoot getTreeRoot() {
        return treeRoot;
    }

    public void setTreeRoot(TreeRoot treeRoot) {
        this.treeRoot = treeRoot;
    }

    public Map<Long, TreeNode> getNodeTreeMap() {
        return nodeTreeMap;
    }

    public void setNodeTreeMap(Map<Long, TreeNode> nodeTreeMap) {
        this.nodeTreeMap = nodeTreeMap;
    }
}
